# Replication Package for Dynamic Persuasion: Decay and Accumulation of Partisan Media Persuasion

## Overview

The study includes three experiments:
- **Experiment 1**: Marijuana policy attitudes (3-wave panel survey)
- **Experiment 2**: Big Tech attitudes with text treatment (2-wave panel)
- **Experiment 3**: Big Tech attitudes with video treatment (2-wave panel)

## Requirements

The analysis requires R with the following packages:

```r
install.packages(c("tidyverse", "data.table", "broom", "Cairo", "ggthemes", 
                   "knitr", "kableExtra", "psych", "xtable", "lfe", 
                   "stargazer", "monomvn"))
```

## Folder Structure

```
replication/
├── Code/
│   ├── main_analysis_marijuana.R   # Experiment 1 analysis
│   ├── main_analysis_tech.R        # Experiments 2 & 3 analysis
│   ├── appendix_tables.R           # Additional appendix tables and figures
│   ├── merge_waves_marijuana.R     # Data merging for Exp 1
│   ├── merge_waves_tech.R          # Data merging for Exp 2 & 3
│   └── Clean Data Functions/       # Data cleaning scripts
├── Data/                           # Survey data (CSV files)
├── Log/                            # R output logs (.Rout files)
└── Output/                         # Figures (PDF) and tables (TeX)
```

## How to Replicate

1. Set your working directory to the `replication` folder.

2. Run the main analysis scripts in order:

```r
# Experiment 1 (Marijuana)
source("Code/main_analysis_marijuana.R")

# Experiments 2 & 3 (Big Tech)
source("Code/main_analysis_tech.R")

# Additional appendix tables
source("Code/appendix_tables.R")
```

## Output

Each script generates the following outputs:

**`main_analysis_marijuana.R`**:
- Figures 3, 6, 7 and Appendix Figures A1
- Tables A2, A3

**`main_analysis_tech.R`**:
- Figures 4, 5 and Appendix Figure A2

**`appendix_tables.R`**:
- Tables A4–A10
- Appendix Figure A3
- Individual question results (`Output/Individual_questions/`)

